package de.piratech.dasding.services.impl;

import org.springframework.stereotype.Service;

import de.piratech.dasding.data.Location;
import de.piratech.dasding.services.Geocoder;

@Service
public class GeocoderImpl implements Geocoder {

  @Override
  public Location resolve(double pLongitude, double pLatitude) {
    Location location = new Location();
    location.setCity("DummyCity - please implement Geocode :(");
    location.setLatitude(pLatitude);
    location.setLongitude(pLongitude);
    location.setName("DummyName- please implement Geocode :(");
    location.setStreet("DummyStreet - please implement Geocode :(");
    location.setZip("DummyZip - please implement Geocode :(");
    return location;
  }

  @Override
  public Location resolve(String street, String zip, String city) {
    Location location = new Location();
    location.setCity(street);
    location.setLatitude(52.519171);
    location.setLongitude(13.406091);
    location.setName("DummyName- please implement Geocode :(");
    location.setStreet(street);
    location.setZip(zip);
    return location;
  }

}
